<!DOCTYPE html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>css实现虚线框</title>
</head>
<body>
	<style type="text/css" media="screen">
		div {
		  padding: 1em;
		  border: 1px dashed transparent;
		  background: linear-gradient(white,white) padding-box,
		  repeating-linear-gradient(-45deg,#ccc 0, #ccc 0.25em,white 0,white 0.75em);
		}
	</style>
	<div>
		
	</div>
</body>
</html>